home *** CD-ROM | disk | FTP | other *** search
- /*
- Include file for Lister
- Copyright 1991 BAF! Technologies
- Geoffrey Faivre-Malloy & Kerry Cianos
- GF7609CSCI KTC0440CSCI
- Bix - mduck
- */
-
- /* if you want lister to verify that the date is correct make sure that this
- * is not commented out when you compile.
- *
- *#define CHECKDATE YES
- */
-
- #define NUMTYPES 9
-
- #include <exec/types.h>
- #include <stdio.h>
- #include <string.h>
- #include <stdlib.h>
- #include <ctype.h>
- #include <time.h>
- #include "Protos.h"
-
- typedef UBYTE (*myfunc_p)(ULONG type,UBYTE *infile);
-
- #define ABORT 0
- #define OK 1
- #define SAME 0x001000
- #define ADD_EXT 0x010000
- #define NOTFOUND 0x100000
- #define ARC 0x000001
- #define ARJ 0x000002
- #define CPIO 0x000004
- #define LHARC 0x000008
- #define LHA 0x000010
- #define SIT 0x000020
- #define TAR 0x000040
- #define ZIP 0x000080
- #define ZOO 0x000100
-
- /* error code defines */
- #define FILE_ERROR 2
- #define NOT_FOUND 3
- #define WRONG_ARCHIVE 4
- #define UNKNOWN 5
-
- #define SEEK_SET 0
- #define SEEK_CUR 1
-
- /* Archive signatures. */
- #define CPIO_SIG "\x30\x37\x30\x37\x30\x37"
- #define SIT_SIG "\x53\x49\x54\x21"
- #define ZIP_SIG "\x50\x4b\x03\x04"
- #define ARJ_SIG "\x60\xea"
- #define ZOO_SIG "\xfd\xc4\xa7\xdc"
-
- /* the months of the year */
- char *months[12] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun",
- "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" };
- char *filetype[NUMTYPES] = { ".arc",".arj",".cpio",".lzh",".lha",".sit",".tar",".zip",".zoo" };
-
- struct TarInfoBlock {
- char name[100];
- char mode[8];
- char uid[8];
- char gid[8];
- char size[12];
- char mtime[12];
- char chksum[8];
- char linkflag[1];
- char linkname[100];
- char rdev[6];
- };
-